<?php


namespace backend\models;


use yii\base\BaseObject;
use yii\queue\JobInterface;

class Test extends BaseObject implements JobInterface
{

    public $url;
    public $file;

    public function execute($queue)
    {
        $data = date("Y-m-d H:i:s");
        file_put_contents("bu.txt", date('Y/m/d H:i:s', time()) . " \t输出结果:" . $data . "\r\n\r\n", FILE_APPEND);
        return true;
    }
}